#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# @Time    : 2021/6/22
# @Author  : Mik
import base64
import hashlib


def md5(data):
    """md5加密处理"""
    data = data + 'test'
    md_5 = hashlib.md5()
    md_5.update(data.encode('utf-8'))
    return md_5.hexdigest()


def bs64(data):
    """base64加密处理"""
    bs = base64.b64encode(data.encode('utf-8'))
    return bs
